package br.pucrio.inf.lac.konoha.hyuga.listeners;

import org.apache.log4j.Logger;

import br.pucrio.inf.lac.konoha.hyuga.common.Grid;

import com.espertech.esper.client.EventBean;
import com.espertech.esper.client.UpdateListener;

public class GridReadUnlockListener implements UpdateListener {

    /** LOGGER. */
    private static Logger LOGGER = Logger.getLogger(GridReadUnlockListener.class.getCanonicalName());

    @Override
    public void update(EventBean[] newEvents, EventBean[] oldEvents) {
        String threadName = Thread.currentThread().getName();
        LOGGER.debug(threadName + " in LISTENER trying to do read unlock.");
        
        Grid.gridReadUnlock();
    }

}
